1. Field of the Invention
The present invention relates to a numerical control system in which a plurality of external signal input and output units (I/O units) are connected to perform input and output of an input signal/output signal (DI/DO signal) between a numerical controller and a machine tool.
2. Description of the Related Art
In a structure in which a plurality of external signal input and output units (I/O units) are connected to perform input and output of an input signal/output signal (DI/DO signal) between a numerical controller and a machine tool (daisy chain connection), the DI/DO signal communicated with the numerical controller varies depending on the configuration of the system, and when the DI/DO signal is captured, an address inside the numerical controller needs to be freely allocated to the DI/DO signal. For this reason, a method which will be described below is used.
<Method of Freely Allocating an External Signal (DI/DO signal) to an Address Inside a Numerical Controller>
FIG. 1 is a diagram illustrating a method of freely allocating an external signal (DI/DO signal) to an address inside a numerical controller in a system including the numerical controller and a plurality of I/O units connected to the numerical controller.
In a structure in which a plurality of external signal input and output units (I/O units) are connected to perform input and output of an input signal/output signal (DI/DO signal) between a numerical controller and a machine tool (not illustrated), the DI/DO signal communicated with the numerical controller varies depending on the configuration of the system, and when the DI/DO signal is captured, an address inside the numerical controller needs to be freely allocated to the DI/DO signal. For this reason, a method which will be described below is used.
1, 2, 3, . . . used in each diagram in the description below represent group IDs. The group IDs are numbers assigned to each of the I/O units in the order of closer positions to the numerical controller.
A, B, C, . . . represent information indicating the type of the units classified based on the number of signal points and functions thereof. For example, “A is a unit having 32 inputs and 24 outputs, and B is an analog input unit”. I, II, III, . . . are not used actually but assigned for the sake of convenience to describe the present invention, as signs for uniquely identifying each of the units.
In FIG. 1, I/O units 1, 2, 3, 4, and 5 are connected to a numerical controller 6 via a signal line 7 using a daisy chain method. The method will be described below with which the numerical controller 6 assigns group IDs to each of the I/O units 1, 2, 3, 4, and 5 when the power supply is turned on, so that an address inside the numerical controller 6 is freely allocated to a DI/DO signal.
When the power supply of the numerical controller 6 is turned on, the numerical controller 6 firstly transmits a signal for setting that includes a group ID. Each of the units having received the signal, when the unit has not yet acquired the group ID thereof, acquires the transmitted group ID and returns information indicating the type of the I/O unit (A, B, C, . . . ) to the numerical controller 6. When the unit has already acquired the group ID thereof, the unit forwards the signal to an I/O unit connected in the lower order. FIG. 1 illustrates an example in which the group Ms of I/O units I to III (1 to 3) have been already set, and the group ID of IV will be set next.
All of the procedures described above are completed, and the numerical controller acknowledges the structure of the I/O units connected thereto. This is performed every time the power supply is turned on. With this process, an address inside the numerical controller can be freely allocated to a DI/DO signal (see Japanese Patent Application Laid-Open No. 2008-191989).
Japanese Patent Application Laid-Open No. 2009-53734 discloses a method with which an I/O unit at a front stage or the numerical controller detects disconnection of an I/O unit at a subsequent stage.
For the numerical controller to assign a group ID to an I/O unit every time, an internal register of the I/O unit storing therein information such as the group ID also needs to be reset every time. With a conventional method, a signal resetting an internal register of an I/O unit is input when the power supply is turned on. For this reason, when the power supply of the numerical controller is turned off/on, the I/O unit also needs to be turned off/on. Because the power supply is not turned off/on with respect to the I/O unit, when the internal register is not reset, group IDs are not correctly assigned and the numerical control system is not normally operated (see FIG. 2).
<Operation Performed when the Internal Register of the I/O unit is not Reset>
For the numerical controller to assign group IDs to the I/O units every time as in the method described above, the internal register of the I/O unit storing therein information such as the group ID needs to be reset every time.
An operation in a case where the internal registers of the I/O units are not reset and the numerical control system is not normally operated when only the power supply of the numerical controller is turned off/on is described below. FIG. 3 is a diagram illustrating an operation performed when an internal register of an I/O unit is not reset in a system including a numerical controller and a plurality of I/O units connected to the numerical controller.
With the conventional method described above with which a DI/DO signal is freely allocated to an address inside the numerical controller, when an I/O unit receives a signal for setting a group ID, the I/O unit acquires the group ID thereof and then forwards the signal to an I/O unit at a subsequent stage. At this point, an I/O unit the internal register of which is not reset and that has a group ID before the reset transmits the signal for setting a group ID to an I/O unit at a subsequent stage without acquiring any group ID for the ID itself. This causes a deviation in the setting of the group ID between the numerical controller and the I/O unit, leading to two kinds of situations described below.
(1) An I/O unit having an erroneously assigned group ID malfunctions (see FIG. 4).
(2) A plurality of I/O units having the same group ID transmit signals to the numerical controller, causing a malfunction in the system (see FIG. 5).
To prevent occurrence of the two problems (1) and (2), the internal registers of the I/O units have to be reset. With the conventional method, a signal resetting an internal register of an I/O unit is input when the power supply is turned on. For this reason, when the power supply of the numerical controller is turned off/on, the I/O unit also needs to be turned off/on. Furthermore, when the numerical controller and the I/O unit are apart from each other and need to have individual power supplies, the power-on timings thereof need to be matched using a relay or other device. This requires time and labor (FIG. 6).
As another method of resetting an internal register of an I/O unit, simultaneous transmission of a reset command is conceivable. However, this method also has a problem. Firstly, because many noises are generated in the FA environment, it is possible that signals cannot be correctly communicated with the noises added thereto. With the method with which a reset command is simultaneously transmitted, when noises are added to the reset command, a problem is caused that internal registers are not correctly reset and the system is not normally operated.